package abs.domain;

import java.io.Serializable;

import java.lang.StringBuilder;

import java.math.BigDecimal;

import java.util.Calendar;
import java.util.Set;

import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;

import javax.xml.bind.annotation.*;

import javax.persistence.*;

/**
 */

@Entity
@NamedQueries({
		@NamedQuery(name = "findAllRetencioness", query = "select myRetenciones from Retenciones myRetenciones"),
		@NamedQuery(name = "findRetencionesByPrimaryKey", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100cdgo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100cdgo", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100cdgo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100cdgoContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100cdgo like ?1"),
		@NamedQuery(name = "findRetencionesByRt100ctac", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100ctac = ?1"),
		@NamedQuery(name = "findRetencionesByRt100ctacContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100ctac like ?1"),
		@NamedQuery(name = "findRetencionesByRt100desc", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100desc = ?1"),
		@NamedQuery(name = "findRetencionesByRt100descContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100desc like ?1"),
		@NamedQuery(name = "findRetencionesByRt100esta", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100esta = ?1"),
		@NamedQuery(name = "findRetencionesByRt100estaContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100esta like ?1"),
		@NamedQuery(name = "findRetencionesByRt100fead", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100fead = ?1"),
		@NamedQuery(name = "findRetencionesByRt100feadAfter", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100fead > ?1"),
		@NamedQuery(name = "findRetencionesByRt100feadBefore", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100fead < ?1"),
		@NamedQuery(name = "findRetencionesByRt100femo", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100femo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100femoAfter", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100femo > ?1"),
		@NamedQuery(name = "findRetencionesByRt100femoBefore", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100femo < ?1"),
		@NamedQuery(name = "findRetencionesByRt100load", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100load = ?1"),
		@NamedQuery(name = "findRetencionesByRt100loadContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100load like ?1"),
		@NamedQuery(name = "findRetencionesByRt100lomo", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100lomo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100lomoContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100lomo like ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv1", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv1 = ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv1Containing", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv1 like ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv2", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv2 = ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv2Containing", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv2 like ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv3", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv3 = ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv3Containing", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv3 like ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv4", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv4 = ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv4Containing", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv4 like ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv5", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv5 = ?1"),
		@NamedQuery(name = "findRetencionesByRt100niv5Containing", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100niv5 like ?1"),
		@NamedQuery(name = "findRetencionesByRt100porc", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100porc = ?1"),
		@NamedQuery(name = "findRetencionesByRt100timo", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100timo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100timoContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100timo like ?1"),
		@NamedQuery(name = "findRetencionesByRt100tipo", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100tipo = ?1"),
		@NamedQuery(name = "findRetencionesByRt100tipoContaining", query = "select myRetenciones from Retenciones myRetenciones where myRetenciones.rt100tipo like ?1") })
@Table(catalog = "absV2", name = "rt100")
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(namespace = "absWeb/abs/domain", name = "Retenciones")
public class Retenciones implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 */

	@Column(name = "rt100cdgo", length = 5, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@Id
	@XmlElement
	String rt100cdgo;
	/**
	 */

	@Column(name = "rt100desc", length = 500, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100desc;
	/**
	 */

	@Column(name = "rt100tipo", length = 1)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100tipo;
	/**
	 */

	@Column(name = "rt100niv1", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100niv1;
	/**
	 */

	@Column(name = "rt100niv2", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100niv2;
	/**
	 */

	@Column(name = "rt100niv3", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100niv3;
	/**
	 */

	@Column(name = "rt100niv4", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100niv4;
	/**
	 */

	@Column(name = "rt100niv5", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100niv5;
	/**
	 */

	@Column(name = "rt100ctac", length = 15, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100ctac;
	/**
	 */

	@Column(name = "rt100porc", scale = 2, precision = 13)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	BigDecimal rt100porc;
	/**
	 */

	@Column(name = "rt100timo", length = 1, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100timo;
	/**
	 */

	@Column(name = "rt100esta", length = 1)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100esta;
	/**
	 */

	@Column(name = "rt100load", length = 30)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100load;
	/**
	 */
	@Temporal(TemporalType.DATE)
	@Column(name = "rt100fead")
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	Calendar rt100fead;
	/**
	 */

	@Column(name = "rt100lomo", length = 30)
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	String rt100lomo;
	/**
	 */
	@Temporal(TemporalType.DATE)
	@Column(name = "rt100femo")
	@Basic(fetch = FetchType.EAGER)
	@XmlElement
	Calendar rt100femo;

	/**
	 */
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumns({ @JoinColumn(name = "rt100nocia", referencedColumnName = "co000nocia", nullable = false) })
	@XmlTransient
	Companias companias;

	/**
	 */
	public void setRt100cdgo(String rt100cdgo) {
		this.rt100cdgo = rt100cdgo;
	}

	/**
	 */
	public String getRt100cdgo() {
		return this.rt100cdgo;
	}

	/**
	 */
	public void setRt100desc(String rt100desc) {
		this.rt100desc = rt100desc;
	}

	/**
	 */
	public String getRt100desc() {
		return this.rt100desc;
	}

	/**
	 */
	public void setRt100tipo(String rt100tipo) {
		this.rt100tipo = rt100tipo;
	}

	/**
	 */
	public String getRt100tipo() {
		return this.rt100tipo;
	}

	/**
	 */
	public void setRt100niv1(String rt100niv1) {
		this.rt100niv1 = rt100niv1;
	}

	/**
	 */
	public String getRt100niv1() {
		return this.rt100niv1;
	}

	/**
	 */
	public void setRt100niv2(String rt100niv2) {
		this.rt100niv2 = rt100niv2;
	}

	/**
	 */
	public String getRt100niv2() {
		return this.rt100niv2;
	}

	/**
	 */
	public void setRt100niv3(String rt100niv3) {
		this.rt100niv3 = rt100niv3;
	}

	/**
	 */
	public String getRt100niv3() {
		return this.rt100niv3;
	}

	/**
	 */
	public void setRt100niv4(String rt100niv4) {
		this.rt100niv4 = rt100niv4;
	}

	/**
	 */
	public String getRt100niv4() {
		return this.rt100niv4;
	}

	/**
	 */
	public void setRt100niv5(String rt100niv5) {
		this.rt100niv5 = rt100niv5;
	}

	/**
	 */
	public String getRt100niv5() {
		return this.rt100niv5;
	}

	/**
	 */
	public void setRt100ctac(String rt100ctac) {
		this.rt100ctac = rt100ctac;
	}

	/**
	 */
	public String getRt100ctac() {
		return this.rt100ctac;
	}

	/**
	 */
	public void setRt100porc(BigDecimal rt100porc) {
		this.rt100porc = rt100porc;
	}

	/**
	 */
	public BigDecimal getRt100porc() {
		return this.rt100porc;
	}

	/**
	 */
	public void setRt100timo(String rt100timo) {
		this.rt100timo = rt100timo;
	}

	/**
	 */
	public String getRt100timo() {
		return this.rt100timo;
	}

	/**
	 */
	public void setRt100esta(String rt100esta) {
		this.rt100esta = rt100esta;
	}

	/**
	 */
	public String getRt100esta() {
		return this.rt100esta;
	}

	/**
	 */
	public void setRt100load(String rt100load) {
		this.rt100load = rt100load;
	}

	/**
	 */
	public String getRt100load() {
		return this.rt100load;
	}

	/**
	 */
	public void setRt100fead(Calendar rt100fead) {
		this.rt100fead = rt100fead;
	}

	/**
	 */
	public Calendar getRt100fead() {
		return this.rt100fead;
	}

	/**
	 */
	public void setRt100lomo(String rt100lomo) {
		this.rt100lomo = rt100lomo;
	}

	/**
	 */
	public String getRt100lomo() {
		return this.rt100lomo;
	}

	/**
	 */
	public void setRt100femo(Calendar rt100femo) {
		this.rt100femo = rt100femo;
	}

	/**
	 */
	public Calendar getRt100femo() {
		return this.rt100femo;
	}

	/**
	 */
	public void setCompanias(Companias companias) {
		this.companias = companias;
	}

	/**
	 */
	public Companias getCompanias() {
		return companias;
	}

	/**
	 */
	public Retenciones() {
	}

	/**
	 * Copies the contents of the specified bean into this bean.
	 *
	 */
	public void copy(Retenciones that) {
		setRt100cdgo(that.getRt100cdgo());
		setRt100desc(that.getRt100desc());
		setRt100tipo(that.getRt100tipo());
		setRt100niv1(that.getRt100niv1());
		setRt100niv2(that.getRt100niv2());
		setRt100niv3(that.getRt100niv3());
		setRt100niv4(that.getRt100niv4());
		setRt100niv5(that.getRt100niv5());
		setRt100ctac(that.getRt100ctac());
		setRt100porc(that.getRt100porc());
		setRt100timo(that.getRt100timo());
		setRt100esta(that.getRt100esta());
		setRt100load(that.getRt100load());
		setRt100fead(that.getRt100fead());
		setRt100lomo(that.getRt100lomo());
		setRt100femo(that.getRt100femo());
		setCompanias(that.getCompanias());
	}

	/**
	 * Returns a textual representation of a bean.
	 *
	 */
	public String toString() {

		StringBuilder buffer = new StringBuilder();

		buffer.append("rt100cdgo=[").append(rt100cdgo).append("] ");
		buffer.append("rt100desc=[").append(rt100desc).append("] ");
		buffer.append("rt100tipo=[").append(rt100tipo).append("] ");
		buffer.append("rt100niv1=[").append(rt100niv1).append("] ");
		buffer.append("rt100niv2=[").append(rt100niv2).append("] ");
		buffer.append("rt100niv3=[").append(rt100niv3).append("] ");
		buffer.append("rt100niv4=[").append(rt100niv4).append("] ");
		buffer.append("rt100niv5=[").append(rt100niv5).append("] ");
		buffer.append("rt100ctac=[").append(rt100ctac).append("] ");
		buffer.append("rt100porc=[").append(rt100porc).append("] ");
		buffer.append("rt100timo=[").append(rt100timo).append("] ");
		buffer.append("rt100esta=[").append(rt100esta).append("] ");
		buffer.append("rt100load=[").append(rt100load).append("] ");
		buffer.append("rt100fead=[").append(rt100fead).append("] ");
		buffer.append("rt100lomo=[").append(rt100lomo).append("] ");
		buffer.append("rt100femo=[").append(rt100femo).append("] ");

		return buffer.toString();
	}

	/**
	 */
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = (int) (prime * result + ((rt100cdgo == null) ? 0 : rt100cdgo.hashCode()));
		return result;
	}

	/**
	 */
	public boolean equals(Object obj) {
		if (obj == this)
			return true;
		if (!(obj instanceof Retenciones))
			return false;
		Retenciones equalCheck = (Retenciones) obj;
		if ((rt100cdgo == null && equalCheck.rt100cdgo != null) || (rt100cdgo != null && equalCheck.rt100cdgo == null))
			return false;
		if (rt100cdgo != null && !rt100cdgo.equals(equalCheck.rt100cdgo))
			return false;
		return true;
	}
}
